package com.gr.staffpm.projects.dao;

import java.util.Date;
import java.util.List;

import com.gr.staffpm.datatypes.Project;
import com.gr.staffpm.datatypes.Task;
import com.gr.staffpm.datatypes.User;


public interface ProjectDAO {

    Project getProject(int projectId);

    Project findProject(String projectName);

    void createProject(Project project);

    List<Project> getAllProjects(User user);

    List<Project> getAllProjects(User user, String property, boolean ascending);

    void deleteProject(int projectId);

    void updateProject(Project project);

    List<Task> getAllTasks(Project project, String property, boolean ascending);

    List<Task> getTasksCreatedBetween(Project project, Date startDate, Date endDate);

    List<Task> getTasksResolvedBetween(Project project, Date startDate, Date endDate);

    Task loadTask(int id);

    boolean checkProjectExists(Project project);

}
